package com.serviceImpl;

import java.util.List;










import org.hibernate.SessionFactory;

import com.bean.CostcheckProduct;
import com.bean.Craft;
import com.bean.CraftShow;
import com.dao.CostcheckProductDao;






/**
 * 工艺等级service
 * @author Administrator
 */
public class CostcheckProductServiceImpl {

	private CostcheckProductDao costcheckProductDao;	//产品核价dao类
	
	
	
	//封装
	public CostcheckProductDao getCostcheckProductDao() {
		return costcheckProductDao;
	}

	public void setCostcheckProductDao(CostcheckProductDao costcheckProductDao) {
		this.costcheckProductDao = costcheckProductDao;
	}


	/**
	 * 查询所有的核价产品service
	 */
	
	public List<CostcheckProduct> getAllCostcheckProduct(String table,String pk,String sort,int PageNumber,int PageSize ,String options){
		
		return costcheckProductDao.getFindCostcheckProduct(table, pk, sort, PageNumber, PageSize, options);
				
	}

	/**
	 * 通过id查找核价service
	 */
	public CostcheckProduct getByidCostcheckProduct (int chId){
		
		return  costcheckProductDao.findById(chId);
		
	}
	
	/**
	 * 通过保存核价service
	 */
	public void saveCostcheckProduct(CostcheckProduct costcheckProduct){
		
		costcheckProductDao.save(costcheckProduct);
	}
	
	/**
	 * 通过保存核价service
	 */
	public void mergeCostcheckProduct(CostcheckProduct costcheckProduct){
		
		costcheckProductDao.merge(costcheckProduct);
	}
}
